<template>
	<view class="list page bgf6 c00">

		<scroll-view scroll-y="true" class="list" @scrolltolower="nextPage">

			<view class="bgff flex flexC flexB aliC rel r7 py20 mt16 mx12 shadow">
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.totalAmount}}元</view>
					<view class="c85 mb8">总营业额</view>
				</view>
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.payAmount}}元</view>
					<view class="c85 mb8">线上预定</view>
				</view>

				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.chargeAmount}}元</view>
					<view class="c85 mb8">余额充值</view>
				</view>

				<view class="flex1">
					<view class="bold6 fs20">{{data.withAmount}}元</view>
					<view class="c85 mb8">已提现</view>
				</view>


			</view>
			<view class="bgff flex flexC flexB aliC rel r7 py20 mt5 mx12 shadow">
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.mtAmount}}元</view>
					<view class="c85 mb8">美团核销</view>
				</view>
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.dyAmount}}元</view>
					<view class="c85 mb8">抖音核销</view>
				</view>
				<view class="flex1">
					<view class="bold6 fs20">{{data.ksAmount}}元</view>
					<view class="c85 mb8">快手核销</view>
				</view>


			</view>

			<view class="bgff flex flexC flexB aliC rel r7 py20 mt5 mx12 shadow">
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.payRate}}元</view>
					<view class="c85 mb8">支付手续费(千6)</view>
				</view>
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.dyRate}}元</view>
					<view class="c85 mb8">抖音手续费</view>
				</view>
				<view class="flex1">
					<view class="bold6 fs20">{{data.mtRate}}元</view>
					<view class="c85 mb8">美团手续费</view>
				</view>

			</view>


			<view class="bgff flex flexC flexB aliC rel r7 py20 mt5 mx12 shadow">
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.balance}}元</view>
					<view class="c85 mb8">账户余额</view>
				</view>
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.keBalance}}元</view>
					<view class="c85 mb8">可提现</view>
				</view>
				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.mtDyUnDis}}元</view>
					<view class="c85 mb8">抖音快手美团待抵扣</view>
				</view>

				<view class="flex1 borr">
					<view class="bold6 fs20">{{data.onlineAmount}}元</view>
					<view class="c85 mb8">酒水销售</view>
				</view>
			</view>

			<button @click="clickDraw" hover-class="none" class="bg41 r40 mt40 ml10 mr10 btn ">立即提现</button>



		</scroll-view>


	</view>
</template>

<script>
	export default {
		data() {
			return {
				data: null,
				selectShop: null

			};
		},
		onLoad(option) {

			var obj = uni.getStorageSync("selectShop");
			if (obj != null) {
				this.selectShop = JSON.parse(obj);
			}
			this.getInfo();

		},
		methods: {



			getInfo() {

				let that = this;
				let param = {

					shop_id: this.selectShop.id
				};

				this.$api.moneyData(param).then(res => {

					if (res.code == 1) {

						that.data = res.data;

					} else {
						uni.showToast({
							title: res.msg,
							icon: 'none'
						});
					}

				})
			},

			clickDraw() {
				uni.navigateTo({
					url: '/other/member/cashIndex'
				})
			},

		}
	}
</script>

<style lang="scss">
	.w100 {
		width: 160rpx;
	}

	.btn {
		line-height: 80rpx;

	}
</style>